package com.student.model;

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * CylFee entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "CYL_Fee", schema = "dbo", catalog = "StudentManager")
public class CylFee implements java.io.Serializable {

	// Fields

	private Long cylFeeId;
	private Student student;
	private Double cylPayment;
	private Double cylUnpayment;
	private Timestamp cylPaymentTime;

	// Constructors

	/** default constructor */
	public CylFee() {
	}

	/** minimal constructor */
	public CylFee(Long cylFeeId, Double cylPayment, Double cylUnpayment,
			Timestamp cylPaymentTime) {
		this.cylFeeId = cylFeeId;
		this.cylPayment = cylPayment;
		this.cylUnpayment = cylUnpayment;
		this.cylPaymentTime = cylPaymentTime;
	}

	/** full constructor */
	public CylFee(Long cylFeeId, Student student, Double cylPayment,
			Double cylUnpayment, Timestamp cylPaymentTime) {
		this.cylFeeId = cylFeeId;
		this.student = student;
		this.cylPayment = cylPayment;
		this.cylUnpayment = cylUnpayment;
		this.cylPaymentTime = cylPaymentTime;
	}

	// Property accessors
	@Id
	@Column(name = "CYL_Fee_id", unique = true, nullable = false, precision = 18, scale = 0)
	@GeneratedValue
	public Long getCylFeeId() {
		return this.cylFeeId;
	}

	public void setCylFeeId(Long cylFeeId) {
		this.cylFeeId = cylFeeId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "Student_id")
	public Student getStudent() {
		return this.student;
	}

	public void setStudent(Student student) {
		this.student = student;
	}

	@Column(name = "CYL_Payment", nullable = false, scale = 4)
	public Double getCylPayment() {
		return this.cylPayment;
	}

	public void setCylPayment(Double cylPayment) {
		this.cylPayment = cylPayment;
	}

	@Column(name = "CYL_Unpayment", nullable = false, scale = 4)
	public Double getCylUnpayment() {
		return this.cylUnpayment;
	}

	public void setCylUnpayment(Double cylUnpayment) {
		this.cylUnpayment = cylUnpayment;
	}

	@Column(name = "CYL_Payment_Time", nullable = false, length = 23)
	public Timestamp getCylPaymentTime() {
		return this.cylPaymentTime;
	}

	public void setCylPaymentTime(Timestamp cylPaymentTime) {
		this.cylPaymentTime = cylPaymentTime;
	}

}